﻿<%@ Page Title="" Language="C#" MasterPageFile="~/Views/Shared/ViewMasterPage1.Master" Inherits="System.Web.Mvc.ViewPage<ComputerShopE3.Models.NGUOI_DUNG>" %>

<asp:Content ID="Content1" ContentPlaceHolderID="head" runat="server">
	<title>User</title>
</asp:Content>

<asp:Content ID="Content2" ContentPlaceHolderID="MainContent" runat="server">

    <h2>Tạo mới</h2>

    <%=ViewData["error"]%>
    <%= Html.ValidationSummary() %>

    <% using (Html.BeginForm()) {%>

        <fieldset>
            <legend>Thông tin</legend>
             <p>
                <label for="TenDangNhap">Tên đăng nhập:</label>
                <%= Html.TextBox("TenDangNhap") %>
                <%= Html.ValidationMessage("TenDangNhap", "*") %>
            </p>
            <p>
                <label for="MatKhau">Mật khẩu:</label>
                <%= Html.Password("MatKhau") %>
                <%= Html.ValidationMessage("MatKhau", "*") %>
            </p>
            <p>
            <%if (ViewData["NGUOI_DUNG"] != null)
              {%>
                <label for="IdNguoiDung">User:</label>
                <%=Html.DropDownList("IdNguoiDung", (SelectList)ViewData["NGUOI_DUNG"])%>
            <%} %>           
             </p>            
            <p>
                <label for="Email">Email:</label>
                <%= Html.TextBox("Email") %>
                <%= Html.ValidationMessage("Email", "*") %>
            </p>
            <p>
                <label for="Ten">Tên:</label>
                <%= Html.TextBox("Ten") %>
                <%= Html.ValidationMessage("Ten", "*") %>
            </p>
            <p>
                <label for="DiaChi">Địa chỉ:</label>
                <%= Html.TextBox("DiaChi") %>
                <%= Html.ValidationMessage("DiaChi", "*") %>
            </p>
            <p>
                <label for="GioiTinh">Giới tính:</label>
                <%= Html.TextBox("GioiTinh") %> (Note: GioiTinh is True or False) <br />
                <%= Html.ValidationMessage("GioiTinh", "*") %>
            </p>
            <p>
                <label for="NgaySinh">Ngày sinh:</label>
                <%= Html.TextBox("NgaySinh") %>
                <%= Html.ValidationMessage("NgaySinh", "*") %>
            </p>
            <p>
                <label for="NgheNghiep">Nghề nghiệp:</label>
                <%= Html.TextBox("NgheNghiep") %>
                <%= Html.ValidationMessage("NgheNghiep", "*") %>
            </p>
            <p>
                <label for="DienThoai">Điện thoại:</label>
                <%= Html.TextBox("DienThoai") %>
                <%= Html.ValidationMessage("DienThoai", "*") %>
            </p>
            <p>
                <input type="submit" value="Create" />
            </p>
        </fieldset>

    <% } %>

    <div>
        <%=Html.ActionLink("Trở lại danh mục", "Index") %>
    </div>

</asp:Content>

<asp:Content ID="Content3" ContentPlaceHolderID="PersonalMenu" runat="server">
</asp:Content>

